var obj={
    name:'larry',
    age:18,
    gender:'男'
}
// 使用for in循环遍历对象 遍历数组
for(var key in obj){
    console.log(key,obj[key],'遍历对象');
}
var arr=[1,2,3,4,5];
for(var index in arr){
    console.log(index,arr[index],'遍历数组');
}